'use strict';

/**
 * @param {Egg.Application} app - egg application
 */
module.exports = app => {
  const { router, controller } = app;
  // test
  router.get('/', controller.home.index);

  // 小程序
  router.get('/minprogram', controller.minprogram.index);
  router.get('/minprogram/maintainMsg', controller.minprogram.maintainMsg);

  // 文章
  router.post('/article/create', controller.article.create);  // 发布文章
  router.get('/article/list', controller.article.lists);    // 文章列表
  router.get('/article/detail', controller.article.details);    // 文章列表
};
